package com.onepower.core.modules.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.onepower.core.modules.repository.entity.MatchScoreRule;
import com.onepower.core.modules.repository.entity.MatchScoreStatusRule;
import com.onepower.core.modules.repository.mapper.MatchScoreRuleMapper;
import com.onepower.core.modules.repository.mapper.MatchScoreStatusRuleMapper;
import com.onepower.core.modules.service.IMatchScoreRuleService;
import com.onepower.core.modules.service.IMatchScoreStatusRuleService;
import org.springframework.stereotype.Service;

@Service
public class IMatchScoreStatusRuleServiceImpl extends ServiceImpl<MatchScoreStatusRuleMapper, MatchScoreStatusRule> implements IMatchScoreStatusRuleService {
    @Override
    public MatchScoreStatusRule getScoreStatusRule(Integer ruleId) {
        MatchScoreStatusRule matchScoreStatusRule = baseMapper.selectByRuleId(ruleId);
        return matchScoreStatusRule;
    }

    @Override
    public void saveOrUpdate(Integer ruleId, Integer status) {
        baseMapper.saveOrUpdate(ruleId,status);
    }
}
